﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using ERPStudio;
using System.Data.SqlClient;

namespace ResUma
{
    public partial class CalculatoareDetaliuFrm : FrmCard
    {
        public CalculatoareDetaliuFrm(ModuleClass mc): base(mc)
        {
            InitializeComponent();
            workConnString = mc.workConnectionString;
        }


        private void CalculatoareDetaliuFrm_Load(object sender, EventArgs e)
        {
            SqlConnection con = DeschideConexiune(workConnString);
            departamenteTableAdapter.Connection = con;
            departamenteTableAdapter.Fill(eSRPDataSet.Departamente, ModuleInfo.CodUnitate);
            this.locatiiTableAdapter.Connection = con;
            this.locatiiTableAdapter.Fill(this.eSRPDataSet.Locatii);
            this.sistemeTableAdapter.Connection = con;
            this.sistemeTableAdapter.Fill(this.eSRPDataSet.Sisteme);
            InchideConexiune(con);

            AddBindingSource(sistemeBindingSource);
            AddTableAdaptor(sistemeTableAdapter.Adapter);

        }
    }
}
